/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package elsimulatorjava;


/**
 *
 * @author corey
 */
public class Floor {
   // public Signal2<Integer, Integer> numberOfPeopleChanged = new Signal2<Integer, Integer>();
    private static int floorCount = 0;
    private int index;
    private String floorName;
    private int people;
    
    Floor(String fname){
        this.floorName = fname;
        this.index = floorCount;
        floorCount++;
    }
    
    void incrementPeople(){
        this.people++;
        //numberOfPeopleChanged.emit(this.index, this.people);
    }
    
    void decrementPeople(){
        this.people--;
       // numberOfPeopleChanged.emit(this.index, this.people);
    }
    
    int getNumberOfPeople(){
        return this.people;
    }
    
    void setFloorName(String fname){
        this.floorName = fname;
    }
    
    String getFloorName(){
        return this.floorName;
    }
    
    static void resetIndex(){
        floorCount = 0;
    }

    public int getIndex() {
        return index;
    }

    public void setNumberOfPeople(int numberOfPeople){
        people = numberOfPeople;
    }
}
